<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"  xml:lang="en-US">
<head>
 <title>pyTrix</title>
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
  <link rel="stylesheet" type="text/css"
        href="http://www.american.edu/cas/econ/gaussres/gauss.css" />
   <meta name="Author" content="Alan G. Isaac" />
   <meta name="Keywords"
               content="Python, econometrics, software, archive, pytrix, American University" />
   <meta name="Description" content="Pyton econometrics source code archive at American Univeristy." />

</head>
<body>

<p style="font-size: x-small">
Last modified: 2011 Apr 24
</p>

<h1>pyTrix</h1>

<p>
License: MIT, unless otherwise specified in the source file.
</p>

<p>
I started pyTrix (TM) on in August 2004 as a place for economists and other to store
statistically and econometrically oriented Python utilities.
It is now part of a larger EconPy (TM) project,
which will include contributions in agent-based simulation.
In addition, a better place to get most of the stats funtionality (and more)
is the <tt>statsmodel</tt> scikit for SciPy.
Please contribute to this archive by send packages, modules, or links to:

<br />
aisaac AT american.edu
</p>

<p>
Browse the <a href="http://econpy.googlecode.com/svn/trunk/pytrix/">code</a>.
Or see the documentation for a description of the code archive: <a href="../doc/index.html">online</a>.
</p>

<p>
This rest of this page is an idiosyncratic sampling of some Python resources for social scientists.
If you are unaware of the computational potential of Python,
you can find a  brief introduction on my
<a href="http://www.american.edu/econ/notes/soft.htm#scipy">Software for Economists</a> page.

</p>

<div>
As free and open source software,
Python supports Claerbout's notion of
<a href="http://sepwww.stanford.edu/research/redoc/cip.html">really reproducible research</a>.
(<a href="http://sepwww.stanford.edu/research/redoc/cip.html">More references</a>.)
<blockquote>
<p>
An article about computational science in a scientific publication
is not the scholarship itself, it is merely advertising of the
scholarship. The actual scholarship is the complete software
development environment and the complete set of instructions which
generated the figures.
<br />
<a href="http://www-stat.stanford.edu/~donoho/Reports/1995/wavelab.pdf">Buckheit and Donoho</a>
</p>
</blockquote>
</div>

<p>
<a href="http://ironpython.net/">IronPython</a> is
an open-source implementation of Python that is integrated with the .NET Framework.
<a href="http://code.google.com/p/ironclad/">ironclad</a>
allows IronPython users to import and use compiled CPython extensions.
</p>

<p>
Comments on parrallel Python:
<br />
If you want to do computations in parallel,
there are at least three alternatives.
<br />
<a href="http://ipython.scipy.org/moin/IPython1">IPython1</a>

is an enhanced Python interactive shell that supports distributed interactive computing.
<br />
The other two require you to link to <a href="http://www-unix.mcs.anl.gov/mpi/">MPI</a>.
You can run a
modified Python linked with mpi,
or you can use regular Python and a module linked with mpi.
You then run your application using mpirun,
just as with a C/C++ based parallel program.
<br />
There exist several python mpi wrappers:
<a href="http://www.cimec.org.ar/python/mpi4py.html">mpi4py</a> (which gets rave reviews
in combination with <a href="http://www.open-mpi.org/">Open MPI</a>),
<a href="http://datamining.anu.edu.au/~ole/pypar/">pypar</a>,
<a href="http://pympi.sourceforge.net">PyMPI</a>.
If you are using <a href="#numpy">NumPy</a>,
note that note all implementations can communicate efficiently with NumPy arrays
(using the low-level C API to pass pointers to arrays).

</p>

<p>
<a href="http://deeplearning.net/software/theano/">Theano</a>
"is a Python library that allows you to define, optimize, and evaluate mathematical expressions involving multi-dimensional arrays efficiently."
Make easy use of your GPU for computation!
</p>


<h2>Python IDEs</h2>

<p>
There are many Python IDEs, but the most commonly used is IDLE,
which is included in standard Python installations.
</p>

<p>
<a href="http://packages.python.org/spyder/">Spyder</a>
is a very interesting alternative.
"Spyder (Scientific PYthon Development EnviRonment)
is a free open-source Python development environment
providing MATLAB-like features in a simple and light-weighted
software."
</p>

<p>
<a href="http://dreampie.sourceforge.net/">DreamPie</a>
tries to improve on <a href="">IDLE</a>
by better supporting TKinter GUIs.
</p>

<p>
<a href="http://sourceforge.net/projects/drpython/">Dr. Python</a>
gets some good reviews. (License: GPL)
</p>

<p>
<a href="http://pythontoolkit.sourceforge.net/">PythonToolKit</a> (License: GPLv3)
also appears well received.
</p>

<h2>GUI</h2>

<p>
<a href="http://www.riverbankcomputing.co.uk/software/pyqt">PyQt</a>
“is a set of Python bindings for Nokia's Qt application framework”.
(License: GPL)
It is an extensive library with a good reputation.
Similar functionality is provided by the newer <a href="http://www.pyside.org/">PySide</a>,
under a more liberal license. (License: LGPL)
</p>

<h2>Econometric and Other Utilities for Python</h2>

<p>
<a href="http://pygsl.sourceforge.net/">pygsl</a>
"provides a Python interface for the GNU scientific library (gsl)".
</p>

<p>
The <a href="IO.py" type="text/plain">IO</a> module is a collection 
input-output utilities.
These are intended to supplement those in SciPy,
or sometimes to provide "light weight" alternatives,
not to provide a full set of services.

</p>

<p>
<a href="pyGAUSS.py" type="text/plain">pyGAUSS</a> is a collection of GAUSS command "look alikes"
for use with SciPy/numpy.
</p>

<p>
<a href="unitroot.py" type="text/plain">unitroot</a> is a collection of unitroot tests
for use with SciPy/numpy.
Since you can access R via Python,
these <a href="http://www.maths.lth.se/help/R/.R/library/urca/html/00Index.html">Unit root and cointegration tests for time series data</a> may also be of interest.
</p>

<p>
<a href="tseries.py" type="text/plain">tseries</a> is a collection of time-seris related objects
for use with SciPy/numpy.
Graphing functionality requires Matplotlib.
</p>

<p>
<a href="pytrix.py" type="text/plain">pytrix</a> is a collection econometric and other utilities
for use with SciPy/numpy.
This is mostly stuff "harvested" from other websites.
</p>

<p>
<a href="http://sourceforge.net/projects/qme-dev/">QME-DEV Workbench</a>
"is a data analysis workbench based on Python, SciPy, Numpy and MatPlotLib(PyLab) and uses wxPython for the GUI."
</p>


<p>
<a href="http://probstat.sourceforge.net/">probstat</a> is a collection of probability and statistics routines for Python (written in C).
<a href="http://www.biopython.org/documentation/">BioPython</a> includes a
<a href="http://www.biopython.org/docs/cookbook/LogisticRegression.html">Logistic Regression</a> implementation.
The <a href="http://www.acooke.org/jara/muac/">Muac</a> distribution includes Python code for computing the 2-dimensional KS (Kolmogorov-Smirnov) test for two samples. (Archived: <a href="./authors/cooke_andrew/ks2.py">ks2.py</a>.)

</p>

<p>
<a href="http://paida.sourceforge.net/">PAIDA</a> is pure Python
and implements the <a href="http://aida.freehep.org/">AIDA</a>
abstract interface for data analysis.
</p>

<p>
<a href="http://www.astro.cornell.edu/staff/loredo/statpy/">StatPy</a> is
"a collection of resources to help you do statistical computing with Python".
</p>

<p>
Linear Programming:
<a href="http://lpsolve.sourceforge.net/5.5/">lp_solve</a> "is a Mixed Integer Linear Programming (MILP) solver" with a Python wrapper. (License: LGPL)
<a href="http://pypi.python.org/pypi/PuLP/1.1">PuLP</a> "provides a nice syntax for the creation of linear problems, and a simple way to call the solvers to perform the optimization." (License: BSD)
</p>

<p>
<a href="http://code.google.com/p/pyamg/">PyAMG</a> "is a library of Algebraic Multigrid (AMG) solvers with a convenient Python interface".
For solving very large linear systems.
</p>

<p>

<a href="http://wlav.web.cern.ch/wlav/pyroot/">PyRoot</a> provides Python bindings for the impressive
<a href="http://root.cern.ch/">Root</a> C++ library for data analysis.
</p>

<p>
Jonathan Taylor offers a numpy/scipy package for some <a href="http://www-stat.stanford.edu/~jtaylo/scipy_stats_models-0.01a.tar.gz">linear statistical models</a>.
<!-- l:\pytrix\authors\taylor_jonathan\scipy_stats_models-0.01a\lib\scipy_stats_models
jonathan.taylor stanford.edu
-->
</p>

<p>
The oddly named <a href="http://textmodeller.sourceforge.net/">TextModeller</a> implements maximum entropy estimation for large sample spaces.
(The name is explained by the applications in the website tutorial.)

</p>

<p>
<a href="http://cars9.uchicago.edu/software/python/mpfit.html">mpfit</a>
does "Levenberg-Marquardt least-squares minimization, based on MINPACK-1".
SciPy also offers minimizers, including constrained minimizers like <code>fmin_cobyla</code>,
which you can use with the loss function of your choice.
</p>

<p>
<a href="http://cheeseshop.python.org/pypi/clnum/">clnum</a>
does rational and arbitrary precision floating point arithmetic.
</p>

<p>

<a href="http://math.colgate.edu:16080/~wweckesser/software/vfgen/">VFGEN</a>
can for generate Python code to be used with the SciPy ODEINT function.
</p>

<p>
<a href="http://claymore.engineer.gvsu.edu/~steriana/Python/pymat.html">PyMat</a> is a Python interface to MatLab.
</p>
<p>
Gary Strangman's <a href="http://www.nmr.mgh.harvard.edu/Neural_Systems_Group/gary/python.html">stats.py</a>
(which needs his <a href="pstat.py">pstat.py</a> list manipulation module).
The stats.py module in <a href="http://www.american.edu/econ/notes/soft.htm#scipy">SciPy</a> is a modification of the Strangman module,
which is more useful if you are using <a href="http://www.american.edu/econ/notes/soft.htm#numpy">numpy</a>.

</p>

<p>
<a href="http://wwwalt.mathematik.uni-mainz.de/~stefan/python/math_lab.py">Stefan Mueller-Stach's Python Math Lab</a> contains potentially useful utilities.
</p>

<p>
Bryn Keller's <a href="http://www.xoltar.org/languages/python/datastruct.py">datastruct.py</a> has useful, lightweight utilities.
<br />
(License: LGPL)
</p>

<p>
<a href="http://sourceforge.net/projects/pykf/">PyKF</a> provides basic Kalman filtering.
</p>

<p>
<a href="https://sourceforge.net/projects/mocapy/">Mocapy</a> "is a Dynamic Bayesian Network toolkit, implemented in Python. It supports discrete, Gaussian, Dirichlet, Kent and Von Mises-Fisher nodes. Inference and learning is done by Gibbs sampling/Monte Carlo-EM (which can be done on a cluster computer)".
</p>

<p>
<a href="https://developer.berlios.de/projects/pbnt/">Python Bayes Network Toolkit</a>
"supports static Bayesian Networks with discrete variables."
</p>

<p>
Mark Hoemmen's <a href="http://www.cs.berkeley.edu/~mhoemmen/bebop/smc.html">Sparse Matrix Converter</a>.
<br />
(License: BSD.)
</p>

<p>
<a href="http://www.med.upenn.edu/bbl/downloads/pyvox/index.shtml">Pyvox</a>
is image processing for neuropsychiatrists,
but others may find the code useful as well.
</p>

<p>
The <a href="http://mdp-toolkit.sourceforge.net">Modular toolkit for Data Processing (MDP)</a> is a Python library to implement data processing elements (nodes) and to combine them into data processing sequences (flows).
Includes Principal Components analysis in its <a href="http://mdp-toolkit.sourceforge.net/#IMNODES">implemented algorithms</a>.
Use MDP together with <a href="http://mdp-toolkit.sourceforge.net/symeig.html">Symeig</a>,
which wraps useful LAPACK eigenvalue functions.
Includes
"Principal Component Analysis (PCA),
Independent Component Analysis (ICA),
Slow Feature Analysis (SFA),
Growing Neural Gas (GNG),
Factor Analysis,
Fisher Discriminant Analysis (FDA),
and Gaussian Classifiers".

</p>

<p>
Ryan Krauss's <a href="http://www.siue.edu/~rkrauss/python_intro.html">control systems toolkit</a>
"is for analyzing linear, time-invariant dynamic systems
and feedback control systems using the Laplace transform."
(License: BSD)
</p>

<p>
Wavelets:
Scipy offers a modest <a href="http://wavelets.scipy.org/">wavelet library</a>.
There is also a separate <a href="http://www.pybytes.com/pywavelets/">PyWavelets</a> module.
</p>

<p>
<a href="http://projects.scipy.org/scipy/scipy/browser/trunk/Lib/sandbox/buildgrid/README.txt?rev=2003">buildgrid</a>
is a Python extension module (in C) to build regular grids from scattered 2D data.
</p>

<p>
<a href="http://cgal-python.gforge.inria.fr/">CGAL-Python</a>
is implemented using Boost.Python to provide Python access to
the Computational Geometry Algorithms Library (a C++ library of geometric algorithms).  
</p>

<p>
OT:
I'm hoping someone will translate Andy Warne's <a href="http://www.texlips.net/svar/source.html">SVAR</a>

Matlab code to numpy very soon.
</p>

<p>
<a href="">PyDX</a> "is a package for working with calculus (differential geometry),
arbitrary precision arithmetic (using gmpy), and interval arithmetic."  (GPL)
(Be sure to consider the <a href="http://gr.anu.edu.au/svn/people/sdburton/pydx/doc/user-guide.html#prerequisites">dependencies</a>.)
It also does automatic differentiation.
</p>

<p>
<a href="http://github.com/b45ch1/pyadolc/wiki">PYADOLC</a>
provides Python bindings to
<a href="https://projects.coin-or.org/ADOL-C">ADOLC</a>.
Great for automatic differentiation.
</p>

<p>
<a href="http://sourceforge.net/projects/salstat/">SalStat</a>
is a Python based SPSS-like statistical analysis package.
</p>

<h2 id="optimize">Optimization</h2>

<ul>
<li>
The <a href="#scipy">SciPy</a> optimization modules.
</li>
<li>
<a href="http://scipy.org/scipy/scikits/wiki/OpenOpt">OpenOpt</a>
provides a unified interface to a variety of solvers.  (License: BSD; Language: Python)
</li>
<li>
<a href="http://nlpy.sourceforge.net/">nlpy</a>

can read optimization problems coded in the <a href="#AMPL">AMPL</a> modeling language
(and by implication problems coded in <a href="#MathProg">MathProg</a>).
</li>
<li>
<a href="http://ffnet.sourceforge.net/">ffnet</a> implements feed-forward neural networks.
</li>
<li>
<a href="http://code.google.com/p/petsc4py/">petsc4py</a> provides Python bindings for the <a href="http://www-unix.mcs.anl.gov/petsc/petsc-as/">Portable, Extensible Toolkit for Scientific Computation (PETSc)</a>.
(License: BSD; PETSc License: mostly public domain but a little GPL)
PETSc is
"a suite of data structures and routines for the scalable (parallel) solution of scientific applications modeled by partial differential equations".

</li>
<li>
<a href="http://www.ctcms.nist.gov/fipy/">FiPy</a> is a finite-volume partial differential equation (PDE) solver, written in Python.
</li>
<li>
<a href="https://pysundials.svn.sourceforge.net/svnroot/pysundials/">PySUNDIALS</a>
allows Python access to the
<a href="https://computation.llnl.gov/casc/sundials/main.html">SUNDIALS</a> (SUite of Nonlinear and DIfferential/ALgebraic equation Solvers)
</li>
<li>
David Cournapeau's
<a href="http://www.ar.media.kyoto-u.ac.jp/members/david/pyem-0.4.1.tar.gz">module for Expectation 
Maximization for Gaussian Mixture Models</a>.

</li>
<li>
<a href="http://sourceforge.net/projects/pythonequations">Python Equations</a>
fit themselves to 2D and 3D data sets.
</li>
<li>
<a href="http://code.google.com/p/pymc/">pymc</a>
"is a python module that implements the Metropolis-Hastings algorithm as a python class, and is extremely flexible and applicable to a large suite of problems."
</li>
</ul>

<h2>Parallelization</h2>

<p>

<a href="http://luispedro.org/software/jug">Jug</a> is a pure Python "Task-Based Parallelization Framework".
</p>


<h2>Simulation</h2>


<p>
<a href="http://www.cam.cornell.edu/~rclewley/cgi-bin/moin.cgi/MainProjectPage">PyDSTools</a>
"is an integrated simulation, modeling and analysis package for dynamical systems".
(License: BSD.)
Depends on <a href="http://www.american.edu/econ/notes/soft.htm#scipy">SciPy</a>.
</p>

<p>
<a href="http://ui505p06-mbs.ntc.zcu.cz/sfe">SFE</a>
"is a finite element solver used so far for simulations in (bio)mechanics and shape optimization of closed channels w.r.t. fluid flow."
(License: GPL)
</p>


<p>
<a href="http://simpy.sourceforge.net/">SimPy</a> supports "object-oriented, process-based discrete-event simulation".
<br />
License: GNU Lesser GPL (LGPL)
</p>

<p>

<a href="http://github.com/cool-RR/GarlicSim-for-Python-2.6">GarlicSim</a>
"is a platform for writing, running and analyzing simulations".
</p>

<p>
<a href="http://pysces.sourceforge.net/">PySCeS: The Python Simulator for Cellular Systems</a>. (License: GPL)
Hint: for larger systems,
increase the parameter mxstep in the odeint function call
from its default of 500 to a higher value (such as 1000 or 3000).  
</p>





<h2>Data Exchange</h2>

<p>
<a href="http://www.pytables.org/">PyTables</a> " is a package for managing hierarchical datasets ... built on top of the HDF5 library".  (License: BSD; Language: Python)
</p>

<p>
<a href="https://sourceforge.net/project/showfiles.php?group_id=143145">pysclint</a>
provides interfaces to major scientific libraries, like HDF, netCDF and MPI.
<a href="http://pypi.python.org/pypi/pupynere/">pupynere</a> is a
"PUre PYthon NEtcdf REader". (Language: Python; License: MIT)
You can also read and write netCDF files with
<a href="http://netcdf4-python.googlecode.com">netcdf4-python</a>.
</p>

<p>
<a href="http://www.pyngl.ucar.edu/Nio.shtml">PyNIO</a>
"is a Python package that allows read and/or write access to a variety of data formats using an interface modelled on netCDF."
(License: University of Illinois/NCSA Open Source License)
</p>

<p>
<a href="http://code.google.com/p/netcdf4-python/">netcdf4-python</a> is a Python interface to netCDF data.
</p>




<h2>Graphics and Graphics Related Applications</h2>

<p>
<a href="http://www.tc.cornell.edu/~myers/PyXL/">PyXL</a>
creates three-dimensional Voronoi tesselations.
Relies on the <a href="http://www.qhull.org">Qhull</a> package.
PyXL generates 3D graphical representations for use with the <a href="www.vtk.org">VTK</a> package.
</p>

<p>
<a href="http://mathema.tician.de/software/pycuda">PyCuda</a>
"lets you access Nvidia‘s CUDA parallel computation API from Python".
(License: MIT/X Consortium license)

</p>

<p>
<a href="http://pyobjc.sourceforge.net/">PyObjC</a> provides
a "bridge" between Python and Objective-C,
allowing you to write
"Cocoa GUI applications on Mac OS X in pure Python".
</p>

<h3>Image Processing</h3>

<p>
<a href="http://sourceforge.net/projects/opencvlibrary">OpenCV</a>
now supports the NumPy array interface.
</p>

<h2>Graphs (Directed and Undirected)</h2>

<p>
<a href="http://code.google.com/p/python-graph/">python-graph</a>
implements a number of standard graph algorithms.
</p>
<p>
You may wish to examine one
effort to produce a standard <a href="http://wiki.python.org/moin/PythonGraphApi">Python Graph API</a>.
Includes a proposal for GraphABC (an abstract base class for graphs).
</p>

<p>
<a href="https://networkx.lanl.gov/">NetworkX</a> is suitable for
"the creation, manipulation, and study of the structure, dynamics, and functions of complex networks."
You can alternatively use <a href="http://cneurocvs.rmki.kfki.hu/igraph/">igraph</a>,
which has a Python wrapper. (License: GPL)

</p>
<p>
<a href="http://gato.sourceforge.net/">Graphics Animation Toolkit (Gato)</a>
</p>
<p>
<a href="https://sourceforge.net/project/showfiles.php?group_id=67624">peak-o-mat</a>
"is a curve fitting program aimed for fast and easy fitting of spectroscopic data, especially if you face a large amount of similar spectra."
</p>

<p>
<a href="http://ffnet.sourceforge.net/">Feed Forward Neural Nets</a>
</p>

<p>

<a href="http://neuroimaging.scipy.org/">NIPY</a> is a collection of neuro-imaging tools for Python.
(License under discussion, but currently GPL)
</p>


<h2>Odds and Ends</h2>

<pre>
BMELibPy_ is a parital translation of the BMElib MATLAB library.
Still uses Numeric.
The variogram methods are complete.
.. _BMELibPy: http://bmelibpy.sourceforge.net


Shapely_ "is a thin wrapper for libgeos_c".
Allows working with 2D geospatial geometries.
Based on GEOS. (License: BSD)

.. _Shapley: http://pypi.python.org/pypi/Shapely


`sftp_client`_ is a simple SSH2 `FTP client`_.

.. _sftp_client: sftp_client.py
.. _`FTP client`: http://www.american.edu/econ/notes/soft.htm#ftp



Easily pass numpy arrays to MATLAB with mlabwrap_.

.. _mlabwrap: http://mlabwrap.sourceforge.net/

</pre>

<p>
<a href="http://www.ctcms.nist.gov/fipy/">FiPy</a>
"is an object oriented, partial differential equation (PDE) solver".
Documentation is very good.
(License: public domain.)
Also see <a href="http://www.ctcms.nist.gov/oof/">OOF</a>.
(License: public domain.)

</p>

<p>
<a href="http://code.google.com/p/pyffmpeg/">PyFFmpeg</a> wraps the FFmpeg library,
allowing audio-visual manipulations via a simple Python interface.
<br />
<a href="http://scipy.org/scipy/scikits">samplerate</a> is a python wrapper around the Sampling Rate Conversion (SRC) library of Erik Castrop de Lopo.  It provides
"a python package to convert sampling rate of audio signals ... using sinc interpolation and polyphase implementation".
<a href="http://www.ar.media.kyoto-u.ac.jp/members/david/pyaudiolab.tar.gz">PyAudioLab</a>
reads and writes audio files as numpy arrays.
Requires <a href="http://www.mega-nerd.com/libsndfile/">libsndfile</a>,
(a cross-platform C library for reading and writing files containing sampled sound). (License: LGPL)
There is <a href="http://www.ar.media.kyoto-u.ac.jp/members/david/softwares/pyaudiolab/index.html">documentation</a>.
Currently no IO capabilities.
<br />
<a href="http://www.pyaudiere.org/">PyAudiere</a> provides a "high-level audio interface for Python".
Depends on the Audiere sound library. (License: LGPL)

<br />
<a href="http://people.csail.mit.edu/hubert/pyaudio/">PyAudio</a> if Python bindings for <a href="http://www.portaudio.com/">PortAudio</a>.
Offers (blocking-mode only) support for IO.
(License: MIT)
<br />
<a href="http://www.freenet.org.nz/python/pyPortAudio/">pyPortAudio</a>
is a "Python interface to the <a href="http://www.portaudio.com/">PortAudio</a> multiplatform audio I/O library".
Requires <a href="http://www.mega-nerd.com/libsndfile/">libsndfile</a>.
<br />
<a href="http://www.freenet.org.nz/python/pyPortAudio/fastaudio.tar.gz">fastaudio.tar.gz</a>

is recommended as an alternative to pyPortAudio (features non-blocking calls, plus far greater stability).
Requires <a href="http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/">Pyrex</a> to build from source,
but there's a pre-built windows binary.
<br />
<a href="http://sndobj.sourceforge.net/#python">PySndObj</a> is SWIG based.
Looks promising.
</p>

<p>
Mac users will want a more up-to-date Python.
Try <a href="http://pythonmac.org/packages/py24-fat/">universal python</a>.
</p>

<p>

The <a href="http://golly.sourceforge.net/">Golly</a> game-of-life simulator is written in C++ but is scriptable in Python.
</p>

<p>
<a href="http://pyvisa.sourceforge.net/">PyVISA</a>
"enables you to control all kinds of measurement equipment through various busses (GPIB, RS232, USB) with Python programs."
</p>

<p>
Windows users can add <a href="http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/93025">command and control speech recognition</a>.
</p>

<p>
<a href="http://mail.python.org/pipermail/python-list/1999-October/014329.html">spawn</a> external commands on Windows platforms.
</p>

<p>
<a href="http://bonsai.ims.u-tokyo.ac.jp/~mdehoon/software/cluster/software.htm#pycluster">PyCluster</a> clustering algorithms, including k-means.
</p>

<h2>Extensibility</h2>

<p>

<a href="https://launchpad.net/pybindgen/">PyBindGen</a> generates Python bindings for C/C++ libraries.
</p>

<h2>Little Tricks</h2>

<p>
Start by reading <a href="http://zephyrfalcon.org/labs/python_pitfalls.html">Python pitfalls</a>. 
</p>

<p>
A simple way to reverse a sequence: <code>seq[::-1]</code>.

</p>

<p>
A fast way to get an element from a set (or other iterable):
<code>for x in myset: break</code>.
</p>

<p>
Here is a way to understand <code>numpy.dot</code>:
the operation uses the last dimension of the first argument and the next-to-last dimension of the second argument.
When given two 1-D arrays, dot() essentially computes the inner product.
When given two 2-D arrays, dot() essentially computes matrix multiplication.  
</p>


</body>
</html> 
